package com.example.demo

import androidx.compose.foundation.ExperimentalFoundationApi
import androidx.compose.material.ExperimentalMaterialApi
import androidx.compose.ui.unit.ExperimentalUnitApi
import androidx.navigation.NavGraphBuilder
import androidx.navigation.NavHostController
//import com.example.chat.ChatFeatureSDK
//import com.example.chat.navigation.chatNestedNavigationGraph
//import com.example.contact.ContactFeatureSDK
//import com.example.contact.navigation.contactNestedNavigationGraph
//import com.example.discover.DiscoverFeatureSDK
//import com.example.discover.navigation.discoverNestedNavigationGraph
import com.example.featuresdk.core.AbstractFeatureSDK
//import com.example.featuresdk.core.FeatureEntry
//import com.example.featuresdk.navigation.sharedNestedNavigationGraph

//Guide:https://developer.android.google.cn/guide/navigation/navigation-nested-graphs
@ExperimentalMaterialApi
@OptIn(ExperimentalUnitApi::class)
@ExperimentalFoundationApi
fun NavGraphBuilder.appNavigationGraph(navHostController: NavHostController, featureSDKs: List<AbstractFeatureSDK>) {

//    sharedNestedNavigationGraph(navHostController, featureSDKs)
//
//    featureSDKs.forEach { featureSdk ->
//        when (featureSdk.key) {
//            ChatFeatureSDK.FEATURE_ENTRY.key -> chatNestedNavigationGraph(navHostController,featureSdk.key)
//            ContactFeatureSDK.FEATURE_ENTRY.key  -> contactNestedNavigationGraph(navHostController,featureSdk.key)
//            DiscoverFeatureSDK.FEATURE_ENTRY.key  -> discoverNestedNavigationGraph(navHostController,featureSdk.key)
//        }
//    }
}
